pub mod basic;
pub mod enhanced;

pub type SerialSender = tokio::sync::mpsc::Sender<Box<[u8]>>;
pub type SerialStdSender = std::sync::mpsc::Sender<Box<[u8]>>;
pub type SerialReceiver = tokio::sync::mpsc::Receiver<(usize, Box<[u8]>)>;
pub type SerialStdReceiver = std::sync::mpsc::Receiver<(usize, Box<[u8]>)>;

pub struct ConnectSerialConfig {
    pub baud_rate: u32,
    pub parity: u32,
    pub data_bits:u32,
    pub stop_bits:u32,
    pub timeout_millis: u64,
    pub buffer_size: usize,
    pub read_delay_millis: u64,
    pub reread_times: u64,
}